package com.tianluo.tianluobookstore.request;

import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import org.springframework.web.multipart.MultipartFile;

import java.math.BigDecimal;
import java.util.Date;

@Data
public class AddBookRequest {
    @NotBlank(message = "书籍标题不能为空")
    private String title;

    @NotBlank(message = "书籍的国际标准书号不能为空")
    private String isbn;

    private String author;

    private String publisher;

    private Date publishedDate;

    @NotNull(message = "书籍价格不能为空")
    private BigDecimal price;

    @NotNull(message = "库存数量不能为空")
    private Integer stockQuantity;

    private MultipartFile coverImage; // 封面图片

    private String description;

    private String category;

    private String creator; // 创建者

}
